<template>
	<view>
		<!-- #ifdef APP-PLUS -->
		<Hearder :name="'资金明细'"></Hearder>
		<!-- #endif -->
		<view class="content">
			<view class="v_one" v-for="(item,index) in listData" :key="item.id">
				<view class="v_two">
					<view>订单号：{{item.order_no}}</view>
					<view>({{item.remarks}})</view>
					<view>{{item.create_time}}</view>
				</view>
				<view class="v_three">{{item.face_value}}</view>
			</view>
		</view>
		<u-skeleton
			rows="4"
			:title="false"
			:loading="loading"
			:rowsHeight="['102rpx', '706rpx', '100rpx', '200rpx']"
			:rowsWidth="['100%', '100%', '100%', '100%']"
			animate
		></u-skeleton>
		<view class="nidata" v-if="listData.length==0">
			<image src="../../static/images/noimg.png"></image>
		</view>
		<shopro-login-modal :showLogin="showLogin" @loginhidden="loginhidden"></shopro-login-modal>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				listData: [],
				page:1,
				showLogin:false,
				loading:true
			}
		},
		onReachBottom() {
			this.page++;
			this.getData()
		},
		onShow() {
			this.getData()
		},
		methods: {
			getData(){
				this.request('/team/orderDetail',{page:this.page}).then(res => {
					if(res.data.code==-500){
						this.showLogin=true
					}
					if (res.data.code == 1) {
						this.listData = this.listData.concat(res.data.data)
					}
					this.loading = false;
				})
			},
			loginhidden(data){
				this.showLogin=data
			},
		}
	}
</script>

<style lang="scss">
	.v_one{
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 24rpx 0rpx;
		border-bottom: 1rpx solid #f0f0f0;
		.v_three{
			font-size: 38rpx;
			color: #EF3800;
		}
		.v_two{
			>view{
				&:first-of-type{
					font-size: 28rpx;
				}
				&:nth-of-type(2){
					font-size: 28rpx;
					color: #EF3800;
					margin-top: 15rpx;
				}
				&:last-of-type{
					font-size: 24rpx;
					margin-top: 40rpx;
					color: #999999;
				}
			}
		}
	}
	.content{
		padding: 30rpx 3%;
	}

</style>
